import numpy as np

# 定义旋转矩阵
theta = -2.355
rotation_matrix = np.array([
    [np.cos(theta), -np.sin(theta)],
    [np.sin(theta), np.cos(theta)]
])

# 定义要旋转的点
local_point = np.array([1.53385, -0.6734])

# 计算旋转后的点
rotated_point = np.dot(rotation_matrix, local_point)

print(rotated_point)



import numpy as np

# 定义旋转角度（弧度）
theta = -2.355

# 计算旋转矩阵的各个元素
cos_theta = np.cos(theta)
sin_theta = np.sin(theta)

# 定义旋转矩阵
rotation_matrix = np.array([
    [cos_theta, -sin_theta],
    [sin_theta, cos_theta]
])

# 定义要旋转的点
local_point = np.array([1.53385, -0.6734])

# 分步骤计算旋转后的点
x_prime = rotation_matrix[0, 0] * local_point[0] + rotation_matrix[0, 1] * local_point[1]
y_prime = rotation_matrix[1, 0] * local_point[0] + rotation_matrix[1, 1] * local_point[1]

rotated_point = np.array([x_prime, y_prime])

print("Rotated Point:", rotated_point)
